package com.example.mybatisplus.service.impl;

import com.example.mybatisplus.model.domain.Class;
import com.example.mybatisplus.mapper.ClassMapper;
import com.example.mybatisplus.service.ClassService;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * <p>
 *  服务实现类
 * </p>
 *
 * @author zzy
 * @since 2024-06-24
 */
@Service
public class ClassServiceImpl extends ServiceImpl<ClassMapper, Class> implements ClassService {
    @Autowired
    private ClassMapper classMapper;

    @Override
    public List<Class> selectClassByMajorId(long id) {
        List<Class> list = classMapper.selectClassByMajorId(id);
        return list;

    }

    @Override
    public List<Class> selectClassByMajorID(Long majorID) {
        List<Class> list = classMapper.selectClassByMajorID(majorID);
        return list;
    }
}
